:@echo off
set JAVA_HOME=C:\Program Files\Java\jdk1.8.0_91
@echo 编译java源文件
javac testdll.java
@echo 生成JNI层头文件
javah testdll
@echo 生成DLL动态库
g++ -m64 -Wl,--add-stdcall-alias testdll.cpp  -I"%JAVA_HOME%\include" -I"%JAVA_HOME%\include\win32" -I"%JAVA_HOME%\include\win32\bridge" -shared -o testdll.dll
@echo 运行程序
java testdll
